package com.taylover.test.animal;

/**
 * @author xyzZero3
 * @date 2025/4/9 21:56
 */
public class Cat extends Animal implements Pet {
    public String name;

    public Cat(String name) {
        super(4);
        this.name = name;
    }

    public Cat() {
        this("");
    }

    @Override
    public void eat() {
        System.out.println("小猫吃饭");
    }

    @Override
    public String getName() {
        return this.name;
    }

    @Override
    public void setName(String name) {
        this.name = name;
    }

    @Override
    public void play() {
        System.out.println("小猫玩游戏");
    }
}
